﻿<MRow>
    @for (var i = 0; i < _bars.Count; i++)
    {
        var bar = _bars[i];
        <MCol @key="i"
          Cols="12"
          Sm="12"
          Md="6"
          Class="my-4">
            <MCard Color="grey lighten-4"
               Flat
               Height="200">
                <MToolbar Color="@bar.Class"
                      Dark="@bar.Dark">
                    <MAppBarNavIcon></MAppBarNavIcon>
                    <MToolbarTitle>Title</MToolbarTitle>
                    <MSpacer></MSpacer>
                    <MButton Icon>
                        <MIcon>mdi-magnify</MIcon>
                    </MButton>
                    <MButton Icon>
                        <MIcon>mdi-heart</MIcon>
                    </MButton>
                    <MButton Icon>
                        <MIcon>mdi-dots-vertical</MIcon>
                    </MButton>
                </MToolbar>
            </MCard>
        </MCol>
    }
</MRow>

@code {
    class Bar
    {
        public string Class { get; set; }

        public bool Dark { get; set; }
    }
    private List<Bar> _bars = new List<Bar>
        {
            new Bar
            {
                Class=""
            },
            new Bar
            {
                Class="class",
                Dark=true
            },
            new Bar
            {
                Class="primary",
                Dark=true
            },
            new Bar
            {
                Class="elevation-0"
            }
        };
}